#define _CRT_SECURE_NO_WARNINGS 1
#include<stdio.h>
#include<string.h>
int main() {
    char arr1[200] = { 0 };
    char arr2[200] = { 0 };
    scanf("%s %s", &arr1, &arr2);
    int sum = 0;
    while (strcmp(arr1, arr2)) {
        for (int i = 0; arr2[i]; i++) {
            if (arr2[i] != arr1[i]) {
                int tmp = arr2[i];
                arr2[i] = arr1[i];
                if (arr2[i + 1] == arr2[i]) {
                    arr2[i + 1] = tmp;
                }
                else
                    arr2[i + 1] = arr1[i];
                sum++;
            }
            
        }
    }
    printf("%d", sum);

    return 0;
}